package com.xmx.authcenter.feign;

import com.xmx.authcenter.dto.MemberDto;
import com.xmx.common.utils.R;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.*;

@FeignClient(value = "user-center")
public interface MemeberFeignClient {
    /**
     * member表
     * @param openId
     * @return
     */
    @GetMapping("usercenter/member/getUserInfoByOpenId")
    R getUserInfoByOpenId(@RequestParam("open_id")String openId);

    @PostMapping("usercenter/member/save")
    R savemember(@RequestBody MemberDto member);

    @PutMapping("usercenter/member/update")
     R updatemember(@RequestBody MemberDto member);

    @GetMapping("usercenter/sysoauthclient/list")
    R getClientDetail(@RequestParam("client_id") String clientId);

    @GetMapping("usercenter/member/getUserInfoByUsername")
    R getUserInfoByUsername(@RequestParam("username")String usernaem);
}
